<div class="container-fluid">
    <div class="row entry_general_header_td" style="height: 60px;" ng-init="saving=false">
        <div class="col-md-10">
            <table>
                <tr>
                    <td>
                        <h4>
                            <span style="white-space: nowrap">
                            <strong style="color: #888;text-transform: uppercase">{{importType}}
                                <span ng-if="linkedSelection"> + {{linkedSelection}}</span> UPLOAD
                            </strong>

                            <strong style="white-space: nowrap" class="folder_name" uib-tooltip="Click to rename"
                                    ng-click="showBulkUploadRenameModal()">
                                <span ng-if="bulkUpload.name">{{bulkUpload.name}}</span>
                                <i ng-if="!bulkUpload.name">Untitled upload</i>
                            </strong>
                            </span>

                            <div class="font-85em">
                                <small style="opacity: 0.7">
                                    <span style="color: #000">Last Updated</span>:
                                    <span ng-show="!saving&&!bulkUpload.lastUpdate"><i
                                            class="fa fa-circle dark-orange"></i> Waiting to auto-save</span>
                                    <span ng-if="saving"><i class="fa fa-gear fa-spin alert_color"></i> Saving...</span>
                                    <span ng-show="saving===false&&bulkUpload.lastUpdate">
                                        <i class="fa fa-circle green"></i> <span
                                            am-time-ago="bulkUpload.lastUpdate"></span>
                                    </span>
                                </small>
                            </div>
                        </h4>
                    </td>
                    <td style="padding-left: 40px">
                        <span ng-if="!bulkUpload||bulkUpload.status!='BULK_EDIT'">
                            <span class="opacity_hover edit_icon font-90em" ng-click="fileUploadModal()">
                                <i style="font-size: 14px; color: #555" class="fa fa-cloud-upload"></i> File Upload
                            </span>

                            <span style="font-weight: normal; color: #ccc">&nbsp;|&nbsp;</span>
                            <div class="uib-dropdown display-inline" uib-dropdown>
                            <span class="opacity_hover edit_icon font-90em uib-dropdown-toggle" uib-dropdown-toggle>
                                <i style="font-size: 14px; color: #555" class="fa fa-link"></i> Link To
                                <span class="caret"></span>
                            </span>
                                <ul class="uib-dropdown-menu">
                                    <li class="cursor_pointer font-80em"><a ng-click="addExistingPart()">Existing
                                        Entry</a>
                                    </li>
                                    <li class="cursor_pointer font-80em" ng-repeat="option in linkOptions">
                                        <a ng-click="addNewPartLink(option.type)"><i>New {{option.display}}</i></a>
                                    </li>
                                </ul>
                            </div>

                            <span ng-if="bulkUpload && bulkUpload.id">
                                <span style="font-weight: normal; color: #ccc">&nbsp;|&nbsp;</span>

                                <span class="opacity_hover edit_icon font-90em" ng-click="setPermissionsModal()">
                                    <i style="font-size: 14px; color: #555" class="fa fa-share-alt"></i> Share
                                </span>
                            </span>
                        </span>
                    </td>
                </tr>
            </table>
        </div>
        <div class="col-md-2 pull-right" style="margin-top: 16px" ng-if="!submitting&&bulkUpload">
            <button type="button" class="btn btn-xs btn-primary"
                    ng-disabled="!bulkUpload||!bulkUpload.entryIdData||!bulkUpload.entryIdData.length"
                    ng-click="submitImportForApproval()">
                <span ng-if="bulkUpload.status==undefined || bulkUpload.status=='IN_PROGRESS'">Submit</span>
                <span ng-if="bulkUpload.status=='PENDING_APPROVAL'">Approve</span>
                <span ng-if="bulkUpload.status=='BULK_EDIT'">Done</span>
            </button>
            <button ng-if="bulkUpload.status==undefined || bulkUpload.status=='IN_PROGRESS'"
                    ng-disabled="!bulkUpload||!bulkUpload.entryIdData||!bulkUpload.entryIdData.length"
                    type="button" class="btn btn-xs btn-default" ng-click="confirmResetFormModal()">
                Reset
            </button>
            <button ng-if="bulkUpload.status=='PENDING_APPROVAL'" type="button" class="btn btn-xs btn-default"
                    ng-click="confirmRejectUploadModal()">
                Reject
            </button>
        </div>

        <div class="col-md-2 pull-right" style="margin-top: 16px" ng-if="submitting">
            <i class="fa fa-spin fa-gear blue"></i> <i class="font-95em">Processing...</i>
        </div>
    </div>
</div>

<div id="dataTable" style="overflow: auto; position: fixed; right:0; left: 260px; top: 182px;"
     class="font-85em"></div>
